//
//  String+Extension.swift
//  EasyDana
//
//  Created by mac on 2024/10/9.
//

import Foundation

extension String {
    //english:india
    private var map: [String: String] {
        return ["Detail produk": "Detil pinjaman", "please read and agree to the <Loan Agreement>": "harap membaca dan menyetujui <Perjanjian Pinjaman>", "All": "Semua", "Apply": "Menerapkan", "Repayment": "Pembayaran", "Finished": "Dilunasi", "Settings": "Pengaturan", "Loan Agreement": "Perjanjian Pinjaman", "Agree and continue": "Setuju dan lanjutkan", "Day": "Hari", "Month": "Bulan", "Year": "Tahun", "<Loan Agreement>" :"<Perjanjian Pinjaman>", "Get code": "Dapatkan kode", "Privacy Agreement": "Perjanjian Privasi", "Enter your phone number": "Masukkan nomor telepon Anda", "Enter verification code": "Masukkan kode verifikasi", "I have read and accept the": "Saya telah membaca dan menerima", "Login": "Masuk", "Please read and agree to the Privacy Policy": "Harap membaca dan menyetujui Kebijakan Privasi"]
    }
    
    var locale: String {
        let gallent = HTTPManager.default.config?.gallant ?? 1
        if gallent == 1 {
            return self
        } else {
            if let value = self.map[self] {
                return value
            }
        }
        return self
    }
}
